//
//  SERegistrationChooseNumViewModel.swift
//  SmartEyeForPatient
//
//  Created by qdsg on 2021/4/21.
//

import HandyJSON

struct SERegistrationChooseNumViewModel {
    let model: SERegistrationChooseNumModel

    var numberOfItems: Int {
        return model.times.count
    }

    func numItem(indexPath: IndexPath) -> SERegistrationNumItem {
        return model.times[indexPath.item]
    }
}

struct SERegistrationChooseNumModel: HandyJSON {
    var registerPeriod: String = ""
    var shiftDate: String = ""
    var times: [SERegistrationNumItem] = []
    /**
     是否需要建档true需要绑卡false无需绑卡
     */
    var needBindCard: Bool = false
    /**
     医院id
     */
    var hospitalId: String = ""
    /**
     医院名称
     */
    var hospitalName: String = ""
}

struct SERegistrationNumItem: HandyJSON {
    /**
     号源id
     */
    var id: String = ""
    /**
     号源编号
     */
    var number: String = ""
    /**
     号源时间
     */
    var sourceTime: String = ""
    /**
     是否可预约 0: 不可预约, 1: 可预约
     */
    var flag: Int = 0
    /**
     号源价格
     */
    var fee: String = ""
}
